{template Public:Page:header}
<div class="container">
  <div class="row"> 
  {template Member:Index:sidebar}
    <div class="col-lg-10 well-col-pl-30">
    <form id="Form">
      <div class="row">
        <div class="well">
          <h3>邮箱验证</h3>
          <hr />
          
         	  <div data-target="#WiredWizardsteps" class="wizard wizard-wired" id="WiredWizard">
                        <ul class="steps">
                            <li class="active" data-target="#wiredstep1"><span class="step">1</span><span class="title">{if $change==1}请输入原{else}填写{/if}邮箱地址</span><span class="chevron"></span></li>
                            <li data-target="#wiredstep2"><span class="step">2</span><span class="title">验证邮箱码</span> <span class="chevron"></span></li>
                            <li data-target="#wiredstep3"><span class="step">3</span><span class="title">认证成功</span> <span class="chevron"></span></li>
                        </ul>
               </div>
                                                    

                <br />
                <br />
                 <div class="row">
                <div class="col-lg-5 col-sm-offset-1">
               		 <div class="form-group">
                            <span class="input-icon">
                                <input type="text" class="form-control" value="" name="email" placeholder="{if $change==1}请输入原{/if}邮箱地址">
                                <i class="fa fa-envelope-o info circular"></i>
                            </span>
                        </div>
                   
                    <div class="form-group">
                            <button class="btn btn-palegreen" type="submit">确 认</button>
                 		    <input name="Submit" type="hidden" value="1"/>
                            <input name="change" type="hidden" value="{echo $change}"/>
                    </div>     
                </div>                          
                </div>
                
                <div class="row">
                  <br />
                <br />
                <div class="col-lg-12">
                <h5>邮箱认证后享受的服务</h5>
                <hr />
                <p>
                <b>邮箱登录</b> 可直接使用“邮箱”登录<br>
                <b>重要事件提醒 </b>进行（支付/提现/选稿/中标）时，自动发送提醒<br>
                <b>找回账号密码</b> 忘记密码时，可使用邮箱短信找回密码。
                </p>
                </div>
                </div>


        </div>
      </div>
      </form>
      
    </div>
  </div>
</div>



<script src="{echo AURL}/js/validation/bootstrapValidator.js"></script>

<script>

        $(document).ready(function () {

 		  $('#Form').bootstrapValidator({
                excluded: [':disabled'],
                feedbackIcons: {
                    valid: 'glyphicon glyphicon-ok',
                    invalid: 'glyphicon glyphicon-remove',
                    validating: 'glyphicon glyphicon-refresh'
                },
				fields: {
					email: {
						validators: {
							notEmpty: {
								message: '邮箱不能为空！'
							},
							emailAddress: {
								message: '邮箱格式有误！'
							}
						}
					}
				},
                submitHandler: function (form) {

				  $.post('{echo U("/post/email/sendcode")}',$("#Form").serialize(), function(json) {
					
					  	$('.bootbox').PhpappProgress({json:json});

				 		return true;
					
				  }, 'json');
				  

				 bootbox.dialog({
					 message: '<div class="progress progress-striped active"><div style="width: 1%" aria-valuemax="100" aria-valuemin="0" aria-valuenow="20" role="progressbar" class="progress-bar progress-bar-info"><span>0%</span></div></div>',
					 title: '<i class="icon fa fa-retweet"></i> 提交中',
					 closeButton: false
				 }).PhpappProgress({time:5000});
			 
				  return false; 
				 
                } 
			
            }) 

        });
	   

</script>

{template Public:Page:footer}